package com.steel.yfmall.cloud.assistant.stock.impl;

import com.steel.yfmall.cloud.assistant.stock.SteelZgFreightInfoBeanService;
import com.steel.yfmall.cloud.assistant.po.stock.SteelZgFreightInfoBean;
import com.steel.yfmall.cloud.assistant.stock.mapper.SteelZgFreightInfoBeanMapper;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Slf4j
@Service
public class SteelZgFreightInfoBeanServiceImpl implements SteelZgFreightInfoBeanService {

    @Resource
    private SteelZgFreightInfoBeanMapper steelZgFreightInfoBeanMapper;


    @Override
    public boolean insertSteelZgFreightInfo(SteelZgFreightInfoBean record) {
        if(record == null || StringUtils.isBlank(record.getFreightPriceNo())){
            return false;
        }


        return steelZgFreightInfoBeanMapper.insertSelective(record) > 0 ? true : false;
    }
}
